package com.ly.heart.mapper;

import java.util.List;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ly.heart.domain.SupplierEntity;
import com.ly.heart.domain.dto.SupplierQueryDto;
import com.ly.heart.domain.vo.SupplierQueryVo;

/**
 * 供应商Mapper接口
 *
 * @author cxl
 * @date 2024-06-16
 */
public interface SupplierMapper extends BaseMapper<SupplierEntity> {
    /**
     * 查询供应商
     *
     * @param id 供应商ID
     * @return 供应商
     */
    SupplierEntity selectSupplierEntityById ( String id );

    /**
     * 查询供应商列表
     *
     * @param supplierEntity 供应商
     * @return 供应商集合
     */
    List<SupplierEntity> selectSupplierEntityList ( SupplierEntity supplierEntity );

    Integer queryCount ( SupplierEntity supplierEntity );

    /**
     * 新增供应商
     *
     * @param supplierEntity 供应商
     * @return 结果
     */
    int insertSupplierEntity ( SupplierEntity supplierEntity );

    /**
     * 修改供应商
     *
     * @param supplierEntity 供应商
     * @return 结果
     */
    int updateSupplierEntity ( SupplierEntity supplierEntity );

    /**
     * 删除供应商
     *
     * @param id 供应商ID
     * @return 结果
     */
    int deleteSupplierEntityById ( String id );

    /**
     * 批量删除供应商
     *
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    int deleteSupplierEntityByIds ( String[] ids );

    /**
     * 供应商选择调用接口
     * @param queryDto
     * @return
     */
    List<SupplierQueryVo> getSupplier(SupplierQueryDto queryDto);

}
